﻿////////////////////////////////////////////////////////////////////
// © Copyright 2007 NeoGeo New Media GmbH (http://www.neogeo.com) //
////////////////////////////////////////////////////////////////////
function createSilverlight()
{
	var scene = new ZoomClient.Page();
	Silverlight.createObjectEx({
		source: "xaml/SilverZoom.xaml",
		parentElement: document.getElementById("SilverlightControlHost"),
		id: "SilverlightControl",
		properties: {
			width: "100%",
			height: "100%",
			version: "1.0"
		},
		events: {
			onLoad: LoadMe
		}
	});
	
	// Give the keyboard focus to the Silverlight control by default
    document.body.onload = function() 
    {
      var silverlightControl = document.getElementById('SilverlightControl');
      if (silverlightControl)
        silverlightControl.focus();
    }
}

if (!window.Silverlight) window.Silverlight = {};

Silverlight.createDelegate = function(instance, method) 
{
	return function() 
	{
		return method.apply(instance, arguments);
	}
}

if (!window.ZoomClient)
	window.ZoomClient = {};

ZoomClient.Page = function() 
{
}